#!/bin/bash
# ifelse.sh - Test for If Else

if (cd /home)||(cd /home/123)
#if ( cd /home/123 )        # if操作成功，执行then
then
    echo $?             # 返回最近执行的一条命令的执行结果 
    echo 'In then'
    echo 'Content of then'
else                    # if支持不成功，执行else
    echo $?
    echo 'In Else'
fi
